package com.umpay.privi.model.sys;

import java.io.Serializable;
import java.sql.Timestamp;
import com.umpay.privi.util.ObjectUtil;
import com.umpay.privi.util.StringUtil;

/** 
 * desc:用户
 * <p>创建人：Ding Zhe 创建日期：Apr 19, 2013 </p>
 * @version V1.0  
 */
public class User implements Serializable {

	private static final long serialVersionUID = 1L;
			
	/**
	 * 用户表主键：用户ID
	 */
	public static final String USERID = "userId";
	public static final String SYSID = "sysId";
		
	//用户ID(登录名);	
	private String userId;
	//密码;	
	private String password;
	//姓名;	
	private String userName;
	//性别(0:女;1:男);	
	private Short sex;
	//电子邮箱;	
	private String email;
	//手机号;	
	private String mobileId;
	//固定电话;	
	private String telephoneNo;
	//创建者，空表示系统创建;	
	private String creator;
	//0：超级管理员；1：系统管理员；2：管理员；3：操作员；;	
	private Short rank;
	//0 正常 1 禁用 2 锁定;	
	private Short state;
	//大于5，用户被禁用;	
	private Short failedLimit;
	//1：运营平台，2：U付企业版;	
	private Short sysId;
	//注册时间;	
	private Timestamp regTime;
	//修改时间;	
	private Timestamp modTime;
	//修改人用户编号;	
	private String modUser;
	//上次登录时间;	
	private Timestamp loginTime;
	//上次退出时间;	
	private Timestamp logoutTime;
	//状态 0 可用 1 删除 ;	
	private Short flag;
	
	private String mediaId;//登录账号（媒介编号）
	
	//mupeng add 2016-10-25 15:09:17
	//上次修改密码时间
	private Timestamp passwdLastModifyTime; 
	//上次登录时间
	private Timestamp lastLoginTime;
	
	public void trim(){
		StringUtil.trimObjectFields(this);
	}
	
	@Override
	public String toString() {
		return ObjectUtil.object2LogStr(this);
	}
			
	public String getUserId(){
		return userId;
	}
			
	public String getPassword(){
		return password;
	}
			
	public String getUserName(){
		return userName;
	}
			
	public Short getSex(){
		return sex;
	}
			
	public String getEmail(){
		return email;
	}
			
	public String getTelephoneNo(){
		return telephoneNo;
	}
			
	public String getCreator(){
		return creator;
	}
			
	public Short getRank(){
		return rank;
	}
			
	public Short getState(){
		return state;
	}
			
	public Short getFailedLimit(){
		return failedLimit;
	}
			
	public Short getSysId(){
		return sysId;
	}
			
	public Timestamp getRegTime(){
		return regTime;
	}
			
	public Timestamp getModTime(){
		return modTime;
	}
			
	public String getModUser(){
		return modUser;
	}
			
	public Timestamp getLoginTime(){
		return loginTime;
	}
			
	public Timestamp getLogoutTime(){
		return logoutTime;
	}
			
	public void setUserId(String userId){
		this.userId = userId;
	}
		
	public void setPassword(String password){
		this.password = password;
	}
		
	public void setUserName(String userName){
		this.userName = userName;
	}
		
	public void setSex(Short sex){
		this.sex = sex;
	}
		
	public void setEmail(String email){
		this.email = email;
	}
		
	public void setTelephoneNo(String telephoneNo){
		this.telephoneNo = telephoneNo;
	}
		
	public void setCreator(String creator){
		this.creator = creator;
	}
		
	public void setRank(Short rank){
		this.rank = rank;
	}
		
	public void setState(Short state){
		this.state = state;
	}
		
	public void setFailedLimit(Short failedLimit){
		this.failedLimit = failedLimit;
	}
		
	public void setSysId(Short sysId){
		this.sysId = sysId;
	}
		
	public void setRegTime(Timestamp regTime){
		this.regTime = regTime;
	}
		
	public void setModTime(Timestamp modTime){
		this.modTime = modTime;
	}
		
	public void setModUser(String modUser){
		this.modUser = modUser;
	}
		
	public void setLoginTime(Timestamp loginTime){
		this.loginTime = loginTime;
	}
		
	public void setLogoutTime(Timestamp logoutTime){
		this.logoutTime = logoutTime;
	}

	public String getMobileId() {
		return mobileId;
	}

	public void setMobileId(String mobileId) {
		this.mobileId = mobileId;
	}

	public Short getFlag() {
		return flag;
	}

	public void setFlag(Short flag) {
		this.flag = flag;
	}

	public String getMediaId() {
		return mediaId;
	}

	public void setMediaId(String mediaId) {
		this.mediaId = mediaId;
	}

	public Timestamp getPasswdLastModifyTime() {
		return passwdLastModifyTime;
	}

	public void setPasswdLastModifyTime(Timestamp passwdLastModifyTime) {
		this.passwdLastModifyTime = passwdLastModifyTime;
	}

	public Timestamp getLastLoginTime() {
		return lastLoginTime;
	}

	public void setLastLoginTime(Timestamp lastLoginTime) {
		this.lastLoginTime = lastLoginTime;
	}	
}